package com.lxujia.ruankao.model;

import org.litepal.annotation.Column;
import org.litepal.crud.LitePalSupport;

import java.util.ArrayList;
import java.util.List;

/**
 * 历年真题表
 */
public class CategoryItem extends LitePalSupport {
    private int id;//自增长 id
    private String period;//期数
    private String periodToShow;//期数（用于展示）
    @Column(defaultValue = "上午")  // 默认值
    private String extInfo;//扩展信息 -- 上午、下午
    private String assetsFile;
    private List<QuestionItem> questionItems = new ArrayList<QuestionItem>(); // 关系：对多

    public CategoryItem() {
    }

    public CategoryItem(String period, String periodToShow, String extInfo) {
        this.period = period;
        this.periodToShow = periodToShow;
        this.extInfo = extInfo;
    }

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getPeriod() {
        return period;
    }

    public void setPeriod(String period) {
        this.period = period;
    }

    public String getExtInfo() {
        return extInfo;
    }

    public void setExtInfo(String extInfo) {
        this.extInfo = extInfo;
    }

    public String getPeriodToShow() {
        return periodToShow;
    }

    public void setPeriodToShow(String periodToShow) {
        this.periodToShow = periodToShow;
    }

    public String getAssetsFile() {
        return assetsFile;
    }

    public void setAssetsFile(String assetsFile) {
        this.assetsFile = assetsFile;
    }

    public List<QuestionItem> getQuestionItems() {
        return questionItems;
    }

    public void setQuestionItems(List<QuestionItem> questionItems) {
        this.questionItems = questionItems;
    }

    @Override
    public String toString() {
        return "period = " + this.period + " ; periodToShow = " + this.periodToShow +
                " ; extInfo = " + this.extInfo + " ; assetsFile = " + this.assetsFile;
    }
}
